<form method="post" id="frmBMI" name="frmBMI" action="{$smarty.const.HOST_VFRIEND}account/basicsave" enctype="multipart/form-data">
    <input type="hidden" name="ptsave" id="ptsave" value="{$intType}" />
	<div class="editForm">    	
        <div class="userInput">
        	<label>Chiều cao (cm):</label>
            <input type="text" name="pheight" id="pheight" value="{if isset($smarty.session.st_height)}{$smarty.session.st_height}{else}{$objUser->height}{/if}" maxlength="3" class="text" onkeypress="javascript: checkPointKey(event);" />
        </div>
        <div class="userInput">
        	<label>Cân nặng (kg):</label>
            <input type="text" name="pweight" id="pweight" value="{if isset($smarty.session.st_weight)}{$smarty.session.st_weight}{else}{$objUser->weight}{/if}" maxlength="3" class="text" onkeypress="javascript: checkPointKey(event);" />
        </div>        
        <div class="userInput">
        	<input type="submit" value="Thay đổi" class="btnSubmit" />
            <input type="button" value="Hủy" class="btnCancel" onclick="javascript:basicClose('{$strView}','{$strEdit}')" />
        </div>
    </div>
</form>
<script type="text/javascript" language="javascript" src="{$smarty.const.HOST_STATICS}js/library/init.js"></script>
{literal}
<script type="text/javascript" language="javascript">
	$(document).ready(function(){		
		$("#frmBMI").validate({							
			errorClass		: "errorMessage",
			errorElement	: "span",
			onfocusout		: false,
			onkeyup			: false,
			rules: {	
				pheight:{
					required	: true,
					min			: 50
				},
				pweight: {
					required	: true,
					min			: 30
				}
				
			},
			messages: {	
				pheight:{
					required	: height_required,
					min			: height_min
				},
				pweight: {
					required	: weight_required,
					min			: weight_min
				}
			},		
			errorPlacement: function(label, element) {			
				var id = element.attr("id");			
				label.insertAfter($("#" + id));			
			},
			submitHandler: function(form) {				
				form.submit();
			}
		});		
	});
	showOther = function(intValue) {
		if(intValue == -1) {
			$(".secOther").show();
		}
		else {
			$(".secOther").hide();
		}
	}
</script>
{/literal}